package com.cmol.peopledetectapp.json;

import java.io.Serializable;

/**
 * json接口
 * 场景类
 */
public class Scene implements Serializable {

    private static Integer COUNT = 0;
    /**
     * 场景ID
     */
    private Integer id;
    /**
     * 场景名
     */
    private String name;
    /**
     * 座位数
     */
    private Integer seatNum;
    /**
     * 人数
     */
    private Integer peopleNum;
    /**
     * 开放状态
     */
    private boolean open;

    public Scene() {
    }

    /**
     * 构造方法
     *
     * @param isOpen    开放状态
     * @param name      场景明
     * @param seatNum   座位数
     * @param peopleNum 人数
     */

    public Scene(String name, Integer seatNum, Integer peopleNum, boolean isOpen, Integer id) {
        this.id = id;
        this.name = name;
        this.seatNum = seatNum;
        this.peopleNum = peopleNum;
        this.open = isOpen;
    }

    public boolean isOpen() {
        return open;
    }

    public void setIsOpen(boolean isOpen) {
        this.open = isOpen;
    }

    public Integer getId() {
        return id;
    }

    public void setId() {
        id = ++COUNT;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getSeatNum() {
        return seatNum;
    }

    public void setSeatNum(Integer seatNum) {
        this.seatNum = seatNum;
    }

    public Integer getPeopleNum() {
        return peopleNum;
    }

    public void setPeopleNum(Integer peopleNum) {
        this.peopleNum = peopleNum;
    }

    public boolean getOpen() {
        return this.open;
    }

    public void setOpen(boolean open) {
        this.open = open;
    }
}
